package com.h3bpm.kumhosunny.comment.beans;

import OThinker.Common.Data.Database.Serialization.PropertySerializeMethod;
import OThinker.Common.Data.Database.Serialization.SerializableObject;
import OThinker.Common.EntityInfo;
import OThinker.Common.FieldInfo;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * @description workflow 评论对象
 * @author qinyt
 * @date 2019/02/28
 */
@EntityInfo(
        tableName = "OT_WorkflowComment",
        indexs = "",
        isChild = false
)
public class WorkflowComment extends SerializableObject implements Serializable {
    private static final long serialVersionUID = 1L;
    public static final String TableName = "OT_WorkflowComment";
    public static final String PropertyName_WorkItemId = "WorkItemId";
    @FieldInfo(
            ColumName = "WorkItemId",
            instance = true,
            serializeMethod = PropertySerializeMethod.ForeignKey,
            length = 0
    )
    private String _WorkItemId;
    public static final String PropertyName_InstanceId = "InstanceId";
    @FieldInfo(
            ColumName = "InstanceId",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private String _InstanceId;
    public static final String PropertyName_Content = "Content";
    @FieldInfo(
            ColumName = "Content",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 2000
    )
    private String _Content;
    public static final String PropertyName_UserId = "UserId";
    @FieldInfo(
            ColumName = "UserId",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private String _UserId;
    public static final String PropertyName_UserName = "UserName";
    @FieldInfo(
            ColumName = "UserName",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private String _UserName;
    public static final String PropertyName_UserAvator = "UserAvator";
    @FieldInfo(
            ColumName = "UserAvator",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private String _UserAvator;
    public static final String PropertyName_NotifyUserIds = "NotifyUserIds";
    @FieldInfo(
            ColumName = "NotifyUserIds",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 2000
    )
    private String _NotifyUserIds;
    public static final String PropertyName_CreatedTime = "CreatedTime";
    @FieldInfo(
            ColumName = "CreatedTime",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private Date _CreatedTime = new Date();
    public static final String PropertyName_ModifiedTime = "ModifiedTime";
    @FieldInfo(
            ColumName = "ModifiedTime",
            instance = true,
            serializeMethod = PropertySerializeMethod.Other,
            length = 0
    )
    private Date _ModifiedTime = new Date();
    private List<WorkflowCommentAttachment> attachments;
    @JsonIgnore
    private String _ContentStr;

    public WorkflowComment() {
    }

    public final String getWorkflowCommentID() {
        return this.getObjectID();
    }

    public String getWorkItemId() {
        return this._WorkItemId;
    }

    public void setWorkItemId(String _WorkItemId) {
        this._WorkItemId = _WorkItemId;
    }

    public final String getInstanceId() {
        return this._InstanceId;
    }

    public final void setInstanceId(String value) {
        this._InstanceId = value;
    }

    public final String getContent() {
        return this._Content;
    }

    public final void setContent(String value) {
        this._Content = value;
    }

    public final String getUserId() {
        return this._UserId;
    }

    public final void setUserId(String value) {
        this._UserId = value;
    }

    public final String getUserName() {
        return this._UserName;
    }

    public final void setUserName(String value) {
        this._UserName = value;
    }

    public final String getUserAvator() {
        return this._UserAvator;
    }

    public final void setUserAvator(String value) {
        this._UserAvator = value;
    }

    public final String getNotifyUserIds() {
        return this._NotifyUserIds;
    }

    public final void setNotifyUserIds(String value) {
        this._NotifyUserIds = value;
    }

    public final Date getCreatedTime() {
        return this._CreatedTime;
    }

    public final void setCreatedTime(Date value) {
        this._CreatedTime = value;
    }

    public final Date getModifiedTime() {
        return this._ModifiedTime;
    }

    public final void setModifiedTime(Date value) {
        if (this._ModifiedTime == null || !this._ModifiedTime.equals(value)) {
            this._ModifiedTime = value;
            this.SetPropertyDirty("ModifiedTime");
        }

    }

    public List<WorkflowCommentAttachment> getAttachments() {
        return this.attachments;
    }

    public void setAttachments(List<WorkflowCommentAttachment> attachments) {
        this.attachments = attachments;
    }

    public final String getContentStr() {
        return this._ContentStr;
    }

    public final void setContentStr(String value) {
        this._ContentStr = value;
    }
}
